﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Array
{
    class Program
    {
        static void Main(string[] args)
        {
            string[] arr = { "李杨", "孙武", "张三", "曹操" };
            string str1= arr[1];
            arr[2] = "诸葛亮";
            string str3 = arr[3];
            Console.WriteLine(str1);
            Console.WriteLine(str3);


            int[] Arr = new int[100];
            for (int i=0;i<100;i++)
            {
                Arr[i] = i + 1;
             }
            int sum = 0;
            foreach (int j in Arr )
            {
                sum = sum + j;
                Console.WriteLine(sum);
            }

            string s = "abcabcabcabc";
            string[] sArr1 = s.Split(new char[1] { 'c' });
            foreach (string i in sArr1)
            {
                Console.WriteLine(i.ToString());
            }
        }
    }
}
